package com.duck.sys.service.impl;

import com.duck.sys.entity.User;
import com.duck.sys.mapper.UserMapper;
import com.duck.sys.service.IUserService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.duck.base.service.impl.BaseServiceImpl;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author lwy
 * @since 2019-02-21
 */
@Service
public class UserServiceImpl extends BaseServiceImpl<UserMapper, User> implements IUserService {

	@Override
	public User queryByUserName(String userName) {
		// TODO Auto-generated method stub
		QueryWrapper<User> queryWrapper = new QueryWrapper<>();
		queryWrapper.eq("user_account", userName);
		return this.getOne(queryWrapper);
	}

}
